#ifndef DEF_MATRICE
#define DEF_MATRICE

#include <cmath>


class Matrice
{
public:

    Matrice();
    Matrice(float *values);
    Matrice(Matrice const &matrice);
    ~Matrice();
	
    Matrice operator*(Matrice const &matrice);
    Matrice& operator=(Matrice const &matrice);
    float* const getValues() const;

    void loadIdentity();
	void perspective(float angle, float ratio, float near, float far);
    void translate(float x, float y, float z);
    void scale(float x, float y, float z);
    void rotate(float angle, float x, float y, float z);	

    void normalizeVector(float *vector);
	void dotProduct(float *resultat, const float *vecteur1, const float *vecteur2);
	void lookAt(float eyeX, float eyeY, float eyeZ, float centerX, float centerY, float centerZ, float upX, float upY, float upZ);

	bool push();
	bool pop();
	void depile();


private:

    float m_values[16];
	Matrice *m_savePrevious;
};

#endif
